package ex.com.jm.food.service.impl;

import java.util.List;

import ex.com.jm.food.dao.CompanyNoticeDao;
import ex.com.jm.food.entity.Notices;
import ex.com.jm.food.service.CompanyNoticeService;

public class CompanyNoticeServiceImpl implements CompanyNoticeService {

	private CompanyNoticeDao companyNoticeDao;
	
	public CompanyNoticeDao getCompanyNoticeDao() {
		return companyNoticeDao;
	}

	public void setCompanyNoticeDao(CompanyNoticeDao companyNoticeDao) {
		this.companyNoticeDao = companyNoticeDao;
	}

	@Override
	public List<Notices> getNotices(int initPage, int pageRow, String comId,
			String title, String s_date, String e_date, String order,
			String sort) {
		// TODO Auto-generated method stub
		return this.getCompanyNoticeDao().getNotices(initPage, pageRow, comId, title, s_date, e_date, order, sort);
	}

	@Override
	public int noticeCount(String comId, String title, String s_date,
			String e_date) {
		// TODO Auto-generated method stub
		return this.getCompanyNoticeDao().noticeCount(comId, title, s_date, e_date);
	}

	@Override
	public Object saveNotice(Notices notices) {
		// TODO Auto-generated method stub
		return this.getCompanyNoticeDao().saveNotice(notices);
	}

	@Override
	public void updateNotices(Notices notices) {
		// TODO Auto-generated method stub
       this.getCompanyNoticeDao().updateNotices(notices);
	}

	@Override
	public boolean updateStatus(Integer status, String id) {
		// TODO Auto-generated method stub
		return this.getCompanyNoticeDao().updateStatus(status, id);
	}

	@Override
	public Notices editNotices(String id) {
		// TODO Auto-generated method stub
		return this.getCompanyNoticeDao().editNotices(id);
	}

	@Override
	public void delNotice(String id) {
		// TODO Auto-generated method stub
       this.getCompanyNoticeDao().delNotice(id);
	}

	@Override
	public Notices checkNotices(String comId) {
		// TODO Auto-generated method stub
		return this.getCompanyNoticeDao().checkNotices(comId);
	}

}
